<?php
class AddtionModel extends ModelBase
{
	private static $_tablePrefix = 'addtion_';
	
	public static function add($table, $data)
	{
		return self::queryInsert(self::$_tablePrefix . $table, $data, false);
	}
	
	public static function update($table, $where, $data)
	{
		return self::queryUpdate(self::$_tablePrefix . $table, $data, $where);
	}
	
	public static function get($table, $aid)
	{
		$where = "aid='$aid'";
		return self::querySelectSingle(self::$_tablePrefix . $table, array('*'), $where);
	}
	
	public static function getList($table, $where='', $fields='*')
	{
		return self::querySelect(self::$_tablePrefix . $table, $where, $fields);
	}
	
	public static function delete($table, $where)
	{
		return self::queryDelete($table, $where);
	}
}